home *** CD-ROM | disk | FTP | other *** search
/ Belgian Amiga Club - ADF Collection / BS1 part 54.zip / BS part 54 / MultiFaXPRO_d1.adf / Install-MFax < prev    next >
Encoding:
Text File  |  1992-12-22  |  6.4 KB  |  326 lines

  1. ; script to install MultiFax professional
  2.  
  3.     ; set up a error cleanup routine
  4.  
  5. (onerror
  6.     (makeassign "MultiFax_Disk" (safe))
  7. )
  8.  
  9. (complete 0)
  10.  
  11.     ; just in case the installation was restarted
  12.  
  13. (makeassign "MultiFax_Disk" (safe))    ; start fresh
  14.  
  15.     ; see if this is really an update
  16.  
  17.     ; if update, be sure they want program in same place
  18.  
  19.     ; if not an update, get a location for program
  20.  
  21. (set mfax_dest
  22.     (tackon
  23.         (askdir
  24.             (prompt "Auf welches Laufwerk oder in welches Verzeichnis soll "
  25.                 "MultiFax installiert werden (Help... beachten!) ?")
  26.             (help "Das Verzeichnis \"MultiFax\" wird auf dem gewünschten "
  27.                 "Laufwerk oder in dem gewünschten Verzeichnis automatisch "
  28.                 "eingerichtet.")
  29.             (default @default-dest)
  30.         )
  31.         "MultiFax"
  32.     )
  33. )
  34.  
  35.     ; now lock on to volume 'mfax'
  36.  
  37. (if (exists mfax_dest)
  38.     (
  39.     (set reinstall
  40.         (askbool
  41.             (prompt "Das Verzeichnis "MultiFax" existiert bereits! "
  42.                 "Soll die Installation trotzdem durchgeführt werden?")
  43.             (help    "JA - Ein bereits eingerichtetes MultiFax professional "
  44.                 "wird überschrieben. Sollte es sich um die Version 2.0 "
  45.                 "handeln, dann wird das MultiFax professional dazugemischt. "
  46.                 "Bei einem bereits bestehenden MultiFax professional "
  47.                 "werden nur diejenigen Dateien überschrieben, die Sie "
  48.                 "in dem nächsten Menü auswählen und die bereits bestehen.\n\n"
  49.                 "NEIN - Die Installation wird nicht durchgeführt.")
  50.             (choices "JA" "NEIN")
  51.         )
  52.     )
  53.     (if (not reinstall)
  54.         (exit)
  55.     )
  56.     )
  57. )
  58.  
  59. (askdisk
  60.     (prompt "Bitte legen Sie die Diskette \"MultiFax Programmdiskette\" in ein Laufwerk.")
  61.     (help    "Die Programme des MultiFax werden auf Ihr System kopiert.")
  62.     (dest  "MultiFax")
  63.     (newname "MultiFax_Disk")
  64. )
  65.  
  66.     ; make MFax drawer & icon if not there
  67.  
  68. (makedir mfax_dest (infos))
  69.  
  70.     ; at this point we have a valid destination, so we tell installer where
  71.     ; the application will end up so the exit page will be correct -- also,
  72.     ; the installation log file (if any) will be copied to the destination
  73. (set @default-dest mfax_dest)
  74.  
  75. (set whichfiles 
  76.     (askoptions
  77.         (prompt "Bitte wählen Sie die zu kopierenden Dateien:")
  78.         (help    "Hiermit können Sie auch eine teilweise Installation durchführen. "
  79.             "Für eine normalle Installation wählen Sie bitte alle Punkte an.")
  80.         (choices "MultiFax-Module und Zeichensätze"
  81.              "MultiFax-Druckertreiber"
  82.              "Parameterdateien"
  83.              "Sprachkataloge"
  84.              "Beispielsfaxe"
  85.              "ARexx Beispiele")
  86.             
  87.     )
  88. )
  89.  
  90.  
  91. (if    (in whichfiles 0)
  92. ; MultiFax Module und Zeichensätze
  93.     (
  94.         (copyfiles
  95.             (source "MultiFax_Disk:MultiFax")
  96.             (dest mfax_dest)
  97.             (infos)
  98.         )
  99.         (copyfiles
  100.             (source "MultiFax_Disk:Server")
  101.             (dest mfax_dest)
  102.             (infos)
  103.         )
  104.         (copyfiles
  105.             (source "MultiFax_Disk:Spooler")
  106.             (dest mfax_dest)
  107.             (infos)
  108.         )
  109.         (copyfiles
  110.             (source "MultiFax_Disk:Desk")
  111.             (dest mfax_dest)
  112.             (infos)
  113.         )
  114.         (copyfiles
  115.             (source "MultiFax_Disk:Logbook")
  116.             (dest mfax_dest)
  117.             (infos)
  118.         )
  119.         (copyfiles
  120.             (source "MultiFax_Disk:View")
  121.             (dest mfax_dest)
  122.         )
  123.         (copyfiles
  124.             (source "MultiFax_Disk:Config")
  125.             (dest mfax_dest)
  126.             (infos)
  127.         )
  128.         (copyfiles
  129.             (source "MultiFax_Disk:MFRexx")
  130.             (dest mfax_dest)
  131.         )
  132.         (copyfiles
  133.             (source "MultiFax_Disk:Letterhead.IFF")
  134.             (dest mfax_dest)
  135.             (infos)
  136.         )
  137.         (copyfiles
  138.             (source "MultiFax_Disk:MF_PICA.fnt")
  139.             (dest mfax_dest)
  140.             (infos)
  141.         )
  142.         (copyfiles
  143.             (source "MultiFax_Disk:MF_ELITE.fnt")
  144.             (dest mfax_dest)
  145.             (infos)
  146.         )
  147.         (copyfiles
  148.             (source "MultiFax_Disk:MF_FINE.fnt")
  149.             (dest mfax_dest)
  150.             (infos)
  151.         )
  152.     )
  153. )
  154.  
  155. (complete 70)
  156.  
  157.  
  158.  
  159. (if    (in whichfiles 1)
  160. ; MultiFax-Druckertreiber
  161.     (copyfiles
  162.         (source "MultiFax_Disk:Devs/Printers/MultiFaxDriver")
  163.         (dest "DEVS:Printers")
  164.     )
  165. )
  166.  
  167. (complete 75)
  168.  
  169.     ; Prüfen, ob in dem Parameter-Verzeichnis bereits eine Fax.INF ist.
  170. (set nonew 0)
  171. (if (not (exists (tackon mfax_dest "Parameter/Fax.INF")))
  172.     (set nonew 1)
  173. )
  174.  
  175. (makedir (tackon mfax_dest "Parameter")    (infos))
  176.  
  177. (if    (in whichfiles 2)
  178. ; Parameterdateien
  179.     (
  180.     (copyfiles
  181.         (source "MultiFax_Disk:Parameter")
  182.         (dest (tackon mfax_dest "Parameter"))
  183.         (infos)
  184.         (all)
  185.     )
  186.     )
  187. )
  188.  
  189.     ; wenn noch keine Fax.INF in dem Parameter-Verzeichnis war, dann wird die
  190.     ; alte Fax.INF aus dem Hauptverzeichnis dorthin kopiert, damit die alten
  191.     ; Einstellungen des MultiFax 2.0 wenigstens ein Grundgerüst abgeben.
  192. (if nonew
  193.     (if( exists (tackon mfax_dest "Fax.INF"))
  194.         (copyfiles
  195.             (source (tackon mfax_dest "Fax.INF"))
  196.             (dest (tackon mfax_dest "Parameter"))
  197.         )
  198.     )
  199. )
  200.  
  201. (complete 80)
  202.  
  203. (tooltype
  204.     (dest mfax_dest)
  205.     (noposition)
  206. )
  207.  
  208.  
  209.    ;
  210.    ; these libraries are necessary for PPage, make sure that they are there:
  211.    ;
  212.  
  213. ;;(if    (in whichfiles 3)
  214. ; Requester-Library
  215. (set docopy 1)
  216. (if    (= @user-level 2)
  217.     (set docopy
  218.         (askbool
  219.             (prompt "Jetzt wird die req.library in das Verzeichnis LIBS: "
  220.                 "kopiert. Das geschieht aber nur, wenn in LIBS: noch "
  221.                 "keine req.library vorliegt oder die dort befindliche "
  222.                 "eine niedrigere Versionsnummer besitzt.\n\nSoll die "
  223.                 "library kopiert werden?")
  224.             (help    "Eine möglicherweise dort befindliche req.library wird "
  225.                 "in LIBS: unter dem Namen \"req_old.library\" abgelegt, "
  226.                 "wenn Sie JA auswählen UND dort noch keine Library mit "
  227.                 "dem Namen \"req_old.library\" vorhanden ist.")
  228.             (choices "JA" "NEIN")
  229.         )
  230.     )
  231. )
  232. (if docopy
  233.     (
  234.         (if    (exists "LIBS:req.library")
  235.             (if    (not (exists "LIBS:req_old.library"))
  236.                 (copyfiles
  237.                     (source "LIBS:req.library")
  238.                     (dest "LIBS:req_old.library")
  239.                     (optional)
  240.                 )
  241.             )
  242.         )
  243.         (copylib 
  244.             (source "MultiFax_Disk:Libs/req.library")
  245.             (dest "LIBS:")
  246.         )
  247.     )
  248. )
  249. ;;)
  250.  
  251.  
  252. (complete 85)
  253.  
  254. (makedir (tackon mfax_dest "Catalogs")    (infos))
  255.  
  256. (if    (in whichfiles 3)
  257. ; Sprachkataloge
  258.     (copyfiles
  259.         (source "MultiFax_Disk:Catalogs")
  260.         (dest (tackon mfax_dest "Catalogs"))
  261.         (infos)
  262.         (all)
  263.     )
  264. )
  265.  
  266.  
  267. (complete 90)
  268.  
  269. (makedir (tackon mfax_dest "Output")    (infos))
  270.  
  271. (makedir (tackon mfax_dest "Input")    (infos))
  272.  
  273.  
  274. (if    (in whichfiles 4)
  275. ; Beispielsfaxe
  276.     (
  277.         (copyfiles
  278.             (source "MultiFax_Disk:Output")
  279.             (dest (tackon mfax_dest "Output"))
  280.             (all)
  281.             (infos)
  282.         )
  283.         (copyfiles
  284.             (source "MultiFax_Disk:Input")
  285.             (dest (tackon mfax_dest "Input"))
  286.             (all)
  287.             (infos)
  288.         )
  289.     )
  290. )
  291.  
  292. (complete 95)
  293.  
  294. (copyfiles
  295.     (source "MultiFax_Disk:ARexx.dok")
  296.     (dest mfax_dest)
  297.     (infos)
  298. )
  299.  
  300. (if    (in whichfiles 5)
  301. ; ARexx Beispiele
  302.     (
  303.         (copyfiles
  304.             (source "MultiFax_Disk:Rexx")
  305.             (dest (tackon mfax_dest "Rexx"))
  306.             (all)
  307.             (infos)
  308.         )
  309.     )
  310. )
  311.  
  312.     ; modify S:User-Startup
  313.  
  314.     ; reinitialize assigns
  315.  
  316. (complete 100)
  317.  
  318.     ; cleanup
  319.  
  320. (makeassign "MultiFax_Disk" (safe))
  321.  
  322.     ; this is not strictly necessary, but doesn't hurt -- there is always
  323.     ; a default (exit) at the end of any script
  324.  
  325. (exit)
  326.